import request from '@/utils/request'

// 查询热销商品管理列表
export function listHotgoods(query) {
  return request({
    url: '/miaomiao/hotgoods/list',
    method: 'get',
    params: query
  })
}

// 查询热销商品管理详细
export function getHotgoods(hotgoodsId) {
  return request({
    url: '/miaomiao/hotgoods/' + hotgoodsId,
    method: 'get'
  })
}

// 新增热销商品管理
export function addHotgoods(data) {
  return request({
    url: '/miaomiao/hotgoods',
    method: 'post',
    data: data
  })
}

// 修改热销商品管理
export function updateHotgoods(data) {
  return request({
    url: '/miaomiao/hotgoods',
    method: 'put',
    data: data
  })
}

// 删除热销商品管理
export function delHotgoods(hotgoodsId) {
  return request({
    url: '/miaomiao/hotgoods/' + hotgoodsId,
    method: 'delete'
  })
}
